package com.attendance.entity;

import java.util.Date;

import javax.persistence.CascadeType;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.ManyToOne;
import javax.persistence.Table;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.staff.entity.Staff;

@Entity
@Table(name="t_late")
public class Late {//迟到
	private Long id;
	private Staff staff;
	private Date clockInTime;//迟到时间
	private float totalTime; //迟到总小时数

	@Id
	@GeneratedValue(strategy=GenerationType.IDENTITY)
	public Long getId() {
		return id;
	}
	@JsonIgnore
	@ManyToOne(cascade=CascadeType.ALL)
	public Staff getStaff() {
		return staff;
	}
	public Date getClockInTime() {
		return clockInTime;
	}
	public void setId(Long id) {
		this.id = id;
	}
	public void setStaff(Staff staff) {
		this.staff = staff;
	}
	public void setClockInTime(Date clockInTime) {
		this.clockInTime = clockInTime;
	}
	public float getTotalTime() {
		return totalTime;
	}
	public void setTotalTime(float totalTime) {
		this.totalTime = totalTime;
	}
	
	
}
